﻿using Colorful.Furniture.IEntity;
using FreeSql.DataAnnotations;
using System;
using System.Collections.Generic;
using Colorful.Furniture.Enum;

namespace Colorful.Furniture.ErpInventoryManagement
{
    /// <summary>
    ///  产品信息表
    /// </summary>
    [Table(Name = "erp_bbs_inventory")]
    public class Inventory : AuditTenantSoftDeleteAggregateRoot
    {
        /// <summary>
        ///   编码
        /// </summary>
        [Column(Name = "id")]
        public Guid Id { get; set; }

        /// <summary>
        ///  产品编号 
        /// </summary>
        [Column(Name = "product_no", StringLength = 12)]
        public string ProductNo { get; set; }

        /// <summary>
        ///   产品名字
        /// </summary>
        [Column(Name = "product_name", StringLength = 50)]
        public string ProductName { get; set; }

        /// <summary>
        ///  图册，方便客户进行区分
        /// </summary>
        [Column(Name = "album", StringLength = 4000)]
        public string Album { get; set; }
        
        /// <summary>
        ///  产品类型
        /// </summary>
        [Column(Name = "product_type")]
        public ProductType? ProductType { get; set; }
        
        /// <summary>
        ///  产品类别
        /// </summary>
        [Column(Name = "category", StringLength = 50)]
        public string Category { get; set; }

        /// <summary>
        ///  产品类别id
        /// </summary>
        [Column(Name = "category_id")]
        public Guid? CategoryId { get; set; }
        
        /// <summary>
        ///  面额
        /// </summary>
        [Column(Name = "face_remark", StringLength = 40)]
        public string FaceRemark { get; set; }
        
        /// <summary>
        /// 面值
        /// </summary>
        [Column(Name = "face_amount", Scale = 2, Precision = 8)]
        public decimal? FaceAmount { get; set; }

        /// <summary>
        ///  状态（0 = 禁用，1 = 启用，2 = 下架，3 = 上架）
        /// </summary>
        [Column(Name = "status")]
        public int? Status { get; set; }
        
        /// <summary>
        ///  排序字段：值越大越靠前
        /// </summary>
        [Column(Name = "sort")]
        public int Sort { get; set; }

        /// <summary>
        ///  京东SKU
        /// </summary>
        [Column(Name = "jd_sku", StringLength = 80)]
        public string JdSku { get; set; }

        /// <summary>
        ///  产品规则
        /// </summary>
        [Column(Name = "rules", StringLength = 2000)]
        public string Rules { get; set; }
        
        /// <summary>
        ///  是否为测试商品（0 = 否；1 = 是；）
        /// </summary>
        [Column(Name = "is_test")]
        public int? IsTest { get; set; }

        /// <summary>
        ///  备注
        /// </summary>
        [Column(Name = "remark", StringLength = 2000)]
        public string Remark { get; set; }

        /// <summary>
        ///  供应商名称合集
        /// </summary>
        [Column(Name = "supplier_name", StringLength = 2000)]
        public string SupplierName { get; set; }

        /// <summary>
        ///  客户名称合集
        /// </summary>
        [Column(Name = "customer_name", StringLength = 2000)]
        public string CustomerName { get; set; }

        /// <summary>
        ///  是否验证邮箱：1 = 是；0 = 否；
        /// </summary>
        [Column(Name = "is_check_email")]
        public int? IsCheckEmail { get; set; }

        /// <summary>
        ///  推广地址 
        /// </summary>
        [Column(Name = "link", StringLength = 600)]
        public string Link { get; set; }

        /// <summary>
        ///  参考链接地址 
        /// </summary>
        [Column(Name = "reference_link", StringLength = 600)]
        public string ReferenceLink { get; set; }

        /// <summary>
        ///  产品日志
        /// </summary>
        public List<InventoryLog> InventoryLogs { get; set; }

        /// <summary>
        ///  产品sku
        /// </summary>
        public List<InventoryProduct> InventorySkus { get; set; }

        /// <summary>
        ///  产品关联客户信息
        /// </summary>
        public List<InventoryWithCustomer> InventoryWithCustomers { get; set; }

        /// <summary>
        ///  产品店铺设置信息
        /// </summary>
        public List<InventoryShop> InventoryShops { get; set; }

        /// <summary>
        ///  备案信息 
        /// </summary>
        [Column(Name = "filings", StringLength = 600)]
        public string Filings { get; set; }

        /// <summary>
        ///  封面图片
        /// </summary>
        [Column(Name = "cover_img", StringLength = 2000)]
        public string CoverImg { get; set; }

        /// <summary>
        ///  输入框背景图
        /// </summary>
        [Column(Name = "background_img", StringLength = 1000)]
        public string BackgroundImg { get; set; }
        
        /// <summary>
        ///  商品内容图-图册
        /// </summary>
        [Column(Name = "content", StringLength = 2000)]
        public string Content { get; set; }

        /// <summary>
        ///  二次确认背景图
        /// </summary>
        [Column(Name = "second_pop_img", StringLength = 1000)]
        public string SecondPopImg { get; set; }

        /// <summary>
        /// 是否跳转其余推广页：0=不跳转；1=跳转；
        /// </summary>
        [Column(Name = "is_jump_other")]
        public int? IsJumpOther { get; set; }

        /// <summary>
        /// 是否二次确认：0=不需要；1=需要；
        /// </summary>
        [Column(Name = "is_confirm")]
        public int? IsConfirm { get; set; }




    }
}
